Field of the Invention
The present invention relates to a printing apparatus having a multi-connection communication function, a method for controlling the printing apparatus, and a storage medium.
Description of the Related Art
With Hypertext Transfer Protocol (HTTP), an information processing apparatus establishes one connection with a server, and performs data communication with the server. To perform this data communication more efficiently, a technique is known in which a plurality of connections is established between the information processing apparatus and the server, and a plurality of data blocks is transmitted and received by using the plurality of the connections. Hereinafter, transmission and reception of data blocks by using a plurality of connections is referred to as multi-connection communication.
Performing multi-connection communication enables using a plurality of connections in parallel and therefore achieves more efficient data communication than with data communication by using one connection. Japanese Patent Application Laid-Open No. 2012-95098 discusses a technique in which an information processing apparatus notifies a server of the maximum number of connections, and the server communicates with the information processing apparatus according to the maximum number of the notified connections.
However, performing multi-connection communication does not necessarily improve the efficiency of data communication depending on a communication environment. In transmitting data by using multi-connection communication, process to divide data occurs. In receiving data by using multi-connection communication, processing for combining the divided data occurs. For example, with a sufficiently high data transmission rate, in consideration of the time required for the division processing and the combination processing, not to perform multi-connection communication may achieve higher efficiency of data communication.